<!DOCTYPE html>
<html>

<head>
    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="edge">
    <meta name="viewport" content="width=device-width, initial-scale=1,maximum-scale=1.0,user-scalable=0">
    <meta content="telephone=no" name="format-detection" />
    <meta name="description" content="">
    <meta name="keywords" content="">
    <title>知识库-我要看</title>
    <link rel="stylesheet" type="text/css" href="css/reset.css">
    <link rel="stylesheet" type="text/css" href="css/swiper.min.css">
    <link rel="stylesheet" type="text/css" href="css/global.css">
    <link rel="stylesheet" type="text/css" href="css/media.css">
    <link rel="stylesheet" type="text/css" href="css/loading.css">
    <script type="text/javascript" src="js/lib/loading.js"></script>
</head>

<body id="app">
    <!-- 头部 -->
    <header class="header">
        <a href="javascript:void(0);" title="用户中心" class="icon userIcon" @click="userSideFn();"></a>
        <!-- <a href="javascript:void(0);" title="用户中心" class="icon userIcon"></a> -->
        <div class="clearfix search-box" @click="search();">
            <input type="button" class="fl search-btn">
            <input type="text" readOnly="true" id="searchword" class="search-txt" placeholder="搜索" value="" maxlength="30">
        </div>
    </header>

    <!-- 我要看 -->
    <section class="padT23 padB23" v-show="!showModal" v-cloak>
        <!-- 轮播 -->
        <div class="swiper-container full2" id="slides">
            <ul class="swiper-wrapper">
                <li class="swiper-slide" v-for="swiper in photos">
                    <a href="{{ swiper.url }}" class="textC j_96 bannerPhoto" title=""><img data-src="{{ swiper.pic }}" src="images/liby.png" alt="" class="loadImg" alt="" /></a>
                </li>
            </ul>
            <div class="pagination"></div>
        </div>
        <!-- tab -->
        <ul class="clearfix tabUl quesTab indexTab">
            <li v-bind:class="{'on':tabs==0}" @click="slides(0,$event)">最新</li>
            <li v-bind:class="{'on':tabs==1}" @click="slides(1,$event)">最热</li>
            <li v-bind:class="{'on':tabs==2}" @click="slides(2,$event)">分类</li>
        </ul>
        <div class="bgff questions">
            <!-- 最新 -->
            <ul id="infoNew" class="tabCont quesCont tabBox" v-if="tabs==0">
                <li v-for="info in infos" v-touch:swipe="swipeLeft($event)" v-touch-options:swipe="{ direction: 'horizontal' }">

                    <div>
                        <a href="articleDetail.html?id={{info.id}}&back=index.html" class="clearfix db">
                            <img :src="info.suffix | path" class="fileIcon" onerror="javascript:this.src='images/icon/type/OTHER.png';this.onerror=null;">
                            <div class="ques">
                                <h3 class="font26 color22 ell" id="title">{{ info.title }}</h3>
                                <span class="db font24 color21 ell">{{ info.content }}</span>
                            </div>
                        </a>
                        <template v-if="info.type.length>0">
                            <a href="meeting.html?id={{info.id}}&name={{info.name}}&back=index.html" class="font18 colorB tips" v-for="info in info.type"><em>{{ info.name }}</em></a>
                        </template>
                        <div class="font18 colorb6 queAuthor">
                            <span>{{ info.author }}</span>
                            <span>{{ info.score }}分</span>
                            <span>{{ info.size }}</span>
                            <span>{{ info.readCount }}阅读过</span>
                            <span>{{ info.date }}</span>
                        </div>
                    </div>
                    <div class="font26 dib shareColl two">
                        <a href="javascript:void(0);" @click="share({shareId:info.id,shareTit:info.title,sharePic:info.suffix,isdoc:true},$event);" class="shareIcon"></a>
                        <a href="javascript:void(0);" @click="Collection({dataID:info.id},$event);" class="collIcon"></a>
                    </div>
                </li>
                <span class="loading-more">加载更多...</span>
            </ul>
            <!-- 最热 -->
            <ul id="infoHot" class="tabCont quesCont tabBox" v-if="tabs==1">
                <li v-for="info in hotInfos" v-touch:swipe="swipeLeft($event)" v-touch-options:swipe="{ direction: 'horizontal' }">
                    <div>
                        <a href="articleDetail.html?id={{info.id}}&back=index.html" class="clearfix db">
                            <img :src="info.suffix | path" onerror="javascript:this.src='images/icon/type/OTHER.png';this.onerror=null;" class="fileIcon">
                            <div class="ques">
                                <h3 class="font26 color22 ell">{{ info.title }}</h3>
                                <span class="db font24 color21 ell">{{ info.content }}</span>
                            </div>
                        </a>
                        <template v-if="info.type.length>0">
                            <a href="meeting.html?id={{info.id}}&name={{info.name}}&back=index.html" class="font18 colorB tips" v-for="info in info.type"><em>{{ info.name }}</em></a>
                        </template>
                        <div class="font18 colorb6 queAuthor">
                            <span>{{ info.author }}</span>
                            <span>{{ info.score }}分</span>
                            <span>{{ info.size }}</span>
                            <span>{{ info.readCount }}阅读过</span>
                            <span>{{ info.date }}</span>
                        </div>
                    </div>
                    <div class="font26 dib shareColl two">
                        <a href="javascript:void(0);" @click="share({shareId:info.id,shareTit:info.title,sharePic:info.suffix,isdoc:true},$event);" class="shareIcon"></a>
                        <a href="javascript:void(0);" @click="Collection({dataID:info.id},$event);" class="collIcon"></a>
                    </div>
                </li>
                <span class="loading-more">加载更多...</span>
            </ul>
            <!-- 分类 -->
            <div id="cate" class="tabCont quesCate tabBox" v-if="tabs==2">
                <div class="padB24 borderspace" v-for="cates in classify">
                    <div class="pr pad24">
                        <span class="db font24 tits">{{ cates.name }}</span>
                        <!-- <a href="javascript:void(0);" class="pa more">全部</a> -->
                    </div>
                    <ul class="clearfix cateList">
                        <template v-if="cates.child.length>0">
                            <li v-for="cates in cates.child"><a href="meeting.html?id={{cates.id}}&name={{cates.name}}&back=index.html" class="cateDate">{{ cates.name }}</a></li>
                        </template>
                    </ul>
                </div>
            </div>
        </div>
    </section>


    <!-- 用户中心 -->
    <section v-show="userSide" v-cloak>
        <div class="popbg" @click="userSideFn();"></div>
        <div class="pad24 userSide">
            <a href="myUserCenter.html?back=index.html" class="db">
                <div class="clearfix nameInfo">
                    <img src="images/user.png" class="head" />
                    <span class="dib font28 colorff name">{{user.userName}}<em class="color3b">({{user.level}})</em><br/><em class="font18">{{user.department}}</em></span>
                    <i class="next"></i>
                </div>
            </a>
            <ul class="font28 sideBox">
                <li><a href="dynamicKnowledge.html?back=index.html" class="db sideDate zsIcon">知识动态</a></li>
                <li><a href="myShare.html?back=index.html" class="db sideDate sjIcon">我的分享</a></li>
                <li><a href="myCare.html?back=index.html" class="db sideDate gzIcon">我的关注</a></li>
                <li><a href="vault.html" class="db sideDate jkIcon">我的金库</a></li>
                <li>
                    <a href="newsList.html" class="db sideDate xxIcon">消息中心</a>
                    <i :class="user.IsNotice>0 ? 'hasNotice' : ''"></i>
                </li>
                <li><a href="myCollect.html?back=index.html" class="db sideDate scIcon">我的收藏</a></li>
                <li><a href="shop.html" class="db sideDate dhIcon">兑换超市</a></li>
                <!-- <logout v-bind:username="user.uid"></logout> -->
            </ul>
        </div>
    </section>

    <share :show.sync="showModal" v-on:share-list="shareReg"></share>
    <!-- template for the modal component -->
    <script type="x/template" id="share-template">
        <!-- 头部 -->
        <header class="header" v-show="show">
            <a href="javascript:;" title="返回" class="icon back" @click="cancel();"></a>
            <div class="clearfix search-box searchBigBox">
                <input type="button" class="fl search-btn" @click="search();">
                <input type="text" id="searchword" class="search-txt" placeholder="搜索" value="" maxlength="30" v-model="query">
            </div>
            <a href="javascript:void(0);" title="确认" @click='ok();' class="text">确认</a>
        </header>

        <!-- 通讯录 -->
        <section class="padT23 addrBook" v-show="show">
            <div v-for="info in users">
                <span class="db pad24 font18 color72">{{info.type}}</span>
                <ul id='uluser' class="padLR24 bgff">
                    <!-- 选中则加上 class="on" -->
                    <li dataID='{{info.uid}}' class="padTB24 font24 color21 borderB" @click="checked($event);" v-for="info in info.userList | filterBy query in 'uname'">
                        {{info.uname }}
                    </li>
                </ul>
            </div>

        </section>
    </script>

    <!-- 底部 -->
    <footer class="clearfix footer" v-if="!showModal">
        <a href="index.html" class="footerIcon on fhome" title="我要看">我要看</a>
        <a href="asking.html" class="footerIcon fques" title="我要问">我要问</a>
        <a href="knowledge.html" class="footerIcon fknow" title="知识圈">知识圈</a>
    </footer>

    <script type="text/javascript" src="js/lib/jquery.min.js"></script>
    <script type="text/javascript" src="js/lib/vue.js"></script>
    <script type="text/javascript" src="js/lib/alert.js"></script>
    <script src="js/lib/hammer.min.js"></script>
    <script src="js/lib/vue-touch.js"></script>
    <script type="text/javascript" src="js/lib/global.js"></script>
    <script type="text/javascript" src="js/lib/swiper.min.js"></script>
    <script type="text/javascript" src="js/app.js"></script>
    <script type="text/javascript" src="js/lib/common.js"></script>
    <script type="text/javascript" src="js/index.js"></script>

    <script type="text/javascript">
        // tab
        /*$('.tabCont:eq(0)').show().siblings().hide();
        $('.tabUl li').bind('click', function () {
            var tab = $('.tabUl li').index(this);
            $('.tabCont').eq(tab).show().siblings().hide();
            $(this).addClass('on').siblings().removeClass('on');
        });*/
        if (localStorage.firstOpen == undefined) {
            localStorage.firstOpen = 1;
            location.href = "startPage.html";
        }
        /*if (window.localStorage) {
            var loca = window.location;
            if (localStorage.getItem('prevPage') !== null) {
                var arr = localStorage.getItem('prevPage').split(',');
                arr.push(loca.pathname + loca.search);
                window.localStorage.setItem('prevPage', arr);
            } else {
                window.localStorage.setItem('prevPage', loca.pathname + loca.search);
            }

        }*/
    </script>
</body>

</html>